
//
//  FindFriendsViewController.h
//  SpendFunk
//
//  Created by dongmh on 4/20/11.
//  Copyright 2011 __MyCompanyName__. All rights reserved.
//

#import <UIKit/UIKit.h>
#import <AddressBook/AddressBook.h>
#import "SA_OAuthTwitterController.h"
#import "MGTwitterEngine.h"
#import "FbGraph.h"
#import "UserProfile.h"

@class SA_OAuthTwitterEngine;
@class TwitterViewController;

@interface FindFriendsViewController : UIViewController <UITableViewDataSource,UITableViewDelegate,SA_OAuthTwitterControllerDelegate,MGTwitterEngineDelegate,NSXMLParserDelegate> {
	
    FbGraph *fbGraph; //Graph API
    
	UIButton *m_pBtnBack;
	UIButton *m_pBtnDone;
    UIButton *m_pBtnLogout;
	
	NSArray *m_pArrContent;
    NSMutableArray *m_pFBTWUsersID;
    NSMutableArray *m_pUserEmail;
    NSMutableArray *m_pArrContactList;
	
	UITableView *m_pTableFindFriends;
	SA_OAuthTwitterEngine				*_engine;
	id<SA_OAuthTwitterControllerDelegate> twdelegate;
	
	//NSArray *m_pArrFriendListTwitter;
	
	// Please wait
	UIView *_blockerView;
	// API
	BOOL isContinueParse;
	NSMutableData *m_pWebData;
	NSString *currentElementValue;
	NSString *currentElement;
	
	int iCurrCount;
	int iCountFriend;
	
	NSMutableDictionary *m_pDictUserInfo;
	NSMutableArray		*m_pArrFriends;
	
	UserProfile *m_pUserPro;
	
}
@property (nonatomic, retain) FbGraph *fbGraph;

-(void)initView;
-(void)onClickBack;
-(void)onClickNext;
//CONTACT LIST
-(NSMutableArray*)getInfoContactList;
//FACEBOOK
-(void)getMeFriends;
-(void)displayFacebook;
-(void)postPictureToFacebook:(UIImage*)image;
-(void)getMyID;
//TWITTER
- (void)displayTwitter;
- (void)getFriendsInFriendidList:(NSArray*)members;

@end
